package com.example.admin.dto;

import com.example.common.enums.EditStoreCountTypeEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotNull;

/**
 * 修改商品库存
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class GoodsEditStoreCountDTO {
    @ApiModelProperty(value = "操作类型", required = true, example = "add/sub")
    @NotNull(message = "请输入具体数量")
    private EditStoreCountTypeEnum type;

    @ApiModelProperty(value = "数量", required = true, example = "1")
    @NotNull(message = "请输入具体数量")
    private Integer quantity;

    @ApiModelProperty(value = "规格id", required = true, example = "1")
    @NotNull(message = "缺少规格id")
    private Integer specId;
}
